<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>表单修饰符</title>
</head>

<body>
    <pre>
     .number将字符串类型的转换为number类型的
     .trim去除数据前后的空格
     .lazy将input事件转换为change事件
    </pre>
    <div class="app">
        <input type="text" v-model.number="num">
        <input type="text" v-model.trim="msg">
        <input type="text" v-model.lazy="val">
        <button @click="change">点击</button>
    </div>
    <script src="./js/vue.js"></script>
    <script>
        var xm = new Vue({
            el: '.app',
            data: {
                num: '',
                msg: '',
                val: ''
            },
            methods: {
                change () {
                    console.log(this.num + 13)
                    console.log(this.msg.length)
                    console.log(this.val)
                }
            }
              
        })

    </script>
</body>

</html>